#ifndef RS485_1_RX_THREAD_H
#define RS485_1_RX_THREAD_H

#include <QObject>
#include <QMutex>
#include <QDebug>
#include <QThread>

#include "serial_port/serial_port.h"

class RS485_1_Rx_Thread : public QObject
{
    Q_OBJECT
public:
    RS485_1_Rx_Thread(Serial_Port* sp = nullptr);
    ~RS485_1_Rx_Thread();

    void stop_thread();
    void rs485_1_port_data_process(char *p_data,unsigned int data_len);

signals:

public slots:
    void slot_rs485_1_port_rx_thread();

private:
    bool stop_flag;
    QMutex stop_mutex;
    Serial_Port *serial_port;
};





#endif
